
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>雷谛科技</title>
<meta name="viewport" content="width=device-width,initial-scale=1" />
<link rel="stylesheet" type="text/css" href="{{ URL::asset('newstyle/css/drink.css?v=1') }}" />

</head>
<body>

<header id="header">
  <h3>全民喝好水</h3>
  <a href="{{ route('customers.index') }}">
    <img src="{{ URL::asset('newstyle/images/icon3.png') }}"alt="" width="15" class="personal">
  </a>
</header>
<section id="section1">
  <ul class="list">
    <li @if($cart == 1) class="active" @endif>
      <a href="{{ route('materials.index',array('cart'=>1)) }}">
        <img src="{{ URL::asset('newstyle/images/icon2.png') }}" alt="" align="absmiddle" width="11">水状况
      </a>
    </li>
    <li @if($cart == 0) class="active" @endif>
      <a href="{{ route('materials.index',array('cart'=>0)) }}">
        <img src="{{ URL::asset('newstyle/images/icon1.png') }}" alt="absmiddle" width="16">水知识
      </a>
    </li>
  </ul>
</section>

<section id="section2">
  <ul>
     @foreach($materials as $material)
    <li>
      <a href="{{ route('materials.show',array('id'=>$material->id,'customer_id'=>$customer->id)) }}">
        <img src="{{ $PATH }}{{ $material->cover }}" alt="" width="70">
        <p>{{ $material->title }}</p>
        <span><i>{{ substr($material->created_at,0,-9) }}</i><em>阅读&nbsp; {{ $material->points }}</em></span>
      </a>
    </li>
    @endforeach
  </ul>
</section>
</body>
</html>
